import service from '.'

const partAPi = {
    getAll(page, name, supplier){
        return service.get('/admin/part',{params:{page, name, supplier}});
    },
    updateInfo(part){
        return service.put('/admin/part',part);
    },
    addInfo(part){
        return service.post('/admin/part',part);
    },
    getById(id){
        return service.get(`/admin/part/${id}`);
    },
    getList() {
        return service.get('/admin/part/list');
    }
}

export default partAPi;